<{include file="public_html/header.html"}>
<{include file="public_html/left_menu.html"}>
<style>
	.layui-table img{max-height: 100px;}
</style>
	<!-- content starts -->
	<blockquote class="layui-elem-quote"><{$action}></blockquote>
	<form class="layui-form layui-form-pane1" method="post" delete_action="/topic/delete">
		<table class="layui-table" lay-even lay-skin="row">
		  	<thead>
			  	<tr>
				  	<th>ID</th>
				  	<th>题目内容</th>
				  	<th>题目类型</th>
				  	<th>操作</th>
			  	</tr>
		  	</thead>   
		  	<tbody>
		  	<{foreach from=$items item=item}>
			  	<tr>
			  		<td class="center">
						<input type="checkbox" name="ids[]" value="<{$item['id']}>" title="<{$item['id']}>">
			  		</td>
			  		<td class="center"><{$item['subject_text']}></td>
			  		<td class="center"><{if $item['type'] == 1}>单选题<{elseif $item['type'] == 2}>多选题<{elseif $item['type'] == 3}>判断题<{elseif $item['type'] == 4}>简答题<{elseif $item['type'] == 5}>填空题<{elseif $item['type'] == 6}>计算题<{/if}></td>
			  		<td class="center">
			  			<a class="layui-btn layui-btn-primary layui-btn-small" href="/topic/show_items/<{$item['id']}>"><i class="layui-icon">&#xe62d;</i>   </a>
						<a class="layui-btn layui-btn-primary layui-btn-small" href="/topic/save_topic_item/<{$item['topic_id']}>/<{$item['id']}>" target="_blank"><i class="layui-icon"></i></a>
						<a class="layui-btn layui-btn-primary layui-btn-small delete_data" href="/topic/delete/<{$item['id']}>"><i class="layui-icon"></i></a>
					</td>
			  	</tr>
		  	<{/foreach}>
		  	<{if $items|count eq 0}>
		  		<tr>
			  		<td class="center" style=" height:120px; text-align:center;line-height:120px;" colspan="6">
						赞无数据！
					</td>
			  	</tr>
		  	<{/if}>
		  	<tr>
				<td class="center" colspan="6">
					<input type="checkbox" lay-filter="checkbox_all" title="全选">
					<button id="delete" class="layui-btn layui-btn-primary layui-btn-small" style="margin-top:4px;"><i class="layui-icon"></i> 批量删除</button>
				</td>
			</tr>
	  		</tbody>
	  	</table>
  	</form>
<{include file="public_html/footer.html"}>